<?php
$invoices = $this->invoices;
?>
<div>
    <table class="table table-striped table-hover">
        <thead>
            <tr>
                <th>ID</th>
                <th>ID-Client</th>
                <th>Destinataire</th>
                <th>Expéditeur</th>
                <th>Adresse</th>
                <th>Date de Facturation</th>
                <th>Date de Livraison</th>
                <th>Condition</th>
                <th>Paiement</th>
                <th>Actions</th>
            </tr>
        <tbody>
            <?php foreach ($invoices->facture as $invoice) : ?>
                <tr>
                    <td><?php echo $invoice->attributes()->id ?></td>
                    <td><?php echo $invoice->attributes()->client ?></td>
                    <td><?php echo $invoice->dest->nom . " " . $invoice->dest->prenom ?></td>
                    <td><?php echo $invoice->exp->nom . " " . $invoice->exp->prenom ?></td>
                    <td><?php echo $invoice->dest->adresse ?></td>
                    <td><?php echo $invoice->dat->fact ?></td>
                    <td><?php echo $invoice->dat->liv ?></td>
                    <td><?php echo $invoice->cond ?></td>
                    <td><?php echo $invoice->paie ?></td>
                    <td><?php echo "Modifier" ?> <p>Supprimer</p></td>
                </tr>
            <?php endforeach; ?>
        </tbody>
    </table>

</div>